<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>NumCpp: nc::Vec2 Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="NumCppLogoDoxygen.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">NumCpp
   &#160;<span id="projectnumber">2.4.0</span>
   </div>
   <div id="projectbrief">A Templatized Header Only C++ Implementation of the Python NumPy Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classnc_1_1_vec2.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="#pub-attribs">Data Fields</a>  </div>
  <div class="headertitle">
<div class="title">nc::Vec2 Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Holds a 2D vector.  
 <a href="classnc_1_1_vec2.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_vec2_8hpp_source.html">Vec2.hpp</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ae34b427d1b6560cce898bf61f9524a80"><td class="memItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ae34b427d1b6560cce898bf61f9524a80">Vec2</a> ()=default</td></tr>
<tr class="separator:ae34b427d1b6560cce898bf61f9524a80"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a93a9f0c675265005a60c77179625ddd2"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a93a9f0c675265005a60c77179625ddd2">Vec2</a> (const <a class="el" href="classnc_1_1_nd_array.html">NdArray</a>&lt; double &gt; &amp;ndArray)</td></tr>
<tr class="separator:a93a9f0c675265005a60c77179625ddd2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abfb713c893dbd31d7c94b4741e82530b"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#abfb713c893dbd31d7c94b4741e82530b">Vec2</a> (const std::initializer_list&lt; double &gt; &amp;inList)</td></tr>
<tr class="separator:abfb713c893dbd31d7c94b4741e82530b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeb48b0300990a5b77919589488ddfe30"><td class="memItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#aeb48b0300990a5b77919589488ddfe30">Vec2</a> (double inX, double inY) noexcept</td></tr>
<tr class="separator:aeb48b0300990a5b77919589488ddfe30"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a271ca2cae96a1df44486fbcc2c0f890f"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a271ca2cae96a1df44486fbcc2c0f890f">angle</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;otherVec) const noexcept</td></tr>
<tr class="separator:a271ca2cae96a1df44486fbcc2c0f890f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abb0f6f8cacc680a464425d908e1e55cc"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#abb0f6f8cacc680a464425d908e1e55cc">clampMagnitude</a> (double maxLength) const noexcept</td></tr>
<tr class="separator:abb0f6f8cacc680a464425d908e1e55cc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a63c2b2b7a16828af770d38176b6cb3aa"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a63c2b2b7a16828af770d38176b6cb3aa">distance</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;otherVec) const noexcept</td></tr>
<tr class="separator:a63c2b2b7a16828af770d38176b6cb3aa"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a231781cc06b8f005a1dda5003498ec99"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a231781cc06b8f005a1dda5003498ec99">dot</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;otherVec) const noexcept</td></tr>
<tr class="separator:a231781cc06b8f005a1dda5003498ec99"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a91e6417e5b9903ed6bee3ad90c0c38f4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a91e6417e5b9903ed6bee3ad90c0c38f4">lerp</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;otherVec, double t) const noexcept</td></tr>
<tr class="separator:a91e6417e5b9903ed6bee3ad90c0c38f4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab6922f6c089b20e9d019301fddc6dc0a"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ab6922f6c089b20e9d019301fddc6dc0a">norm</a> () const noexcept</td></tr>
<tr class="separator:ab6922f6c089b20e9d019301fddc6dc0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8d8a3ec28ef8336ab02dcd964a3e836c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a8d8a3ec28ef8336ab02dcd964a3e836c">normalize</a> () const noexcept</td></tr>
<tr class="separator:a8d8a3ec28ef8336ab02dcd964a3e836c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac83768c682c162ec9dffe1bfb9637338"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ac83768c682c162ec9dffe1bfb9637338">operator!=</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;rhs) const noexcept</td></tr>
<tr class="separator:ac83768c682c162ec9dffe1bfb9637338"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72ac39ba88f909cb5552f6b379509f81"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a72ac39ba88f909cb5552f6b379509f81">operator*=</a> (double scaler) noexcept</td></tr>
<tr class="separator:a72ac39ba88f909cb5552f6b379509f81"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af441d4bbee40c07f9b86fbd056ff637e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#af441d4bbee40c07f9b86fbd056ff637e">operator+=</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;rhs) noexcept</td></tr>
<tr class="separator:af441d4bbee40c07f9b86fbd056ff637e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a21b1c9c0aa0b7e8886f1b4a7c255bb9e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a21b1c9c0aa0b7e8886f1b4a7c255bb9e">operator+=</a> (double scaler) noexcept</td></tr>
<tr class="separator:a21b1c9c0aa0b7e8886f1b4a7c255bb9e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a13a2bbc2595248211e0bc97de51e13b5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a13a2bbc2595248211e0bc97de51e13b5">operator-=</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;rhs) noexcept</td></tr>
<tr class="separator:a13a2bbc2595248211e0bc97de51e13b5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abfb0b00888fa37d52a895d06f2b39133"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#abfb0b00888fa37d52a895d06f2b39133">operator-=</a> (double scaler) noexcept</td></tr>
<tr class="separator:abfb0b00888fa37d52a895d06f2b39133"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1a1c875b11ea5571cb2b71778a692472"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a1a1c875b11ea5571cb2b71778a692472">operator/=</a> (double scaler) noexcept</td></tr>
<tr class="separator:a1a1c875b11ea5571cb2b71778a692472"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af04a7f20ae8ac7a59ae44f7819668fa0"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#af04a7f20ae8ac7a59ae44f7819668fa0">operator==</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;rhs) const noexcept</td></tr>
<tr class="separator:af04a7f20ae8ac7a59ae44f7819668fa0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa5cb2f954360d7be97c443da16694383"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#aa5cb2f954360d7be97c443da16694383">project</a> (const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;otherVec) const noexcept</td></tr>
<tr class="separator:aa5cb2f954360d7be97c443da16694383"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad5f0e922730d66c57630ae5c7847e15a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classnc_1_1_nd_array.html">NdArray</a>&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ad5f0e922730d66c57630ae5c7847e15a">toNdArray</a> () const</td></tr>
<tr class="separator:ad5f0e922730d66c57630ae5c7847e15a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acd4277d3a9acded9199afef378e1907c"><td class="memItemLeft" align="right" valign="top">std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#acd4277d3a9acded9199afef378e1907c">toString</a> () const</td></tr>
<tr class="separator:acd4277d3a9acded9199afef378e1907c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:a265ae124776dd84b657c4ff6d7677352"><td class="memItemLeft" align="right" valign="top">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a265ae124776dd84b657c4ff6d7677352">down</a> () noexcept</td></tr>
<tr class="separator:a265ae124776dd84b657c4ff6d7677352"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ade3f4342726264a1493f91ae80ab24ca"><td class="memItemLeft" align="right" valign="top">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ade3f4342726264a1493f91ae80ab24ca">left</a> () noexcept</td></tr>
<tr class="separator:ade3f4342726264a1493f91ae80ab24ca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab84fdd231058aa0343e2249e209855bf"><td class="memItemLeft" align="right" valign="top">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ab84fdd231058aa0343e2249e209855bf">right</a> () noexcept</td></tr>
<tr class="separator:ab84fdd231058aa0343e2249e209855bf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a82fc65cffdae5c0ebd50fece54b56d4c"><td class="memItemLeft" align="right" valign="top">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a82fc65cffdae5c0ebd50fece54b56d4c">up</a> () noexcept</td></tr>
<tr class="separator:a82fc65cffdae5c0ebd50fece54b56d4c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-attribs"></a>
Data Fields</h2></td></tr>
<tr class="memitem:a36a67b9395b397e1b8e9364a39a5c458"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#a36a67b9395b397e1b8e9364a39a5c458">x</a> { 0.0 }</td></tr>
<tr class="separator:a36a67b9395b397e1b8e9364a39a5c458"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad7a5bc1612f92f7e49112cf58caeaace"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnc_1_1_vec2.html#ad7a5bc1612f92f7e49112cf58caeaace">y</a> { 0.0 }</td></tr>
<tr class="separator:ad7a5bc1612f92f7e49112cf58caeaace"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Holds a 2D vector. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="ae34b427d1b6560cce898bf61f9524a80"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae34b427d1b6560cce898bf61f9524a80">&#9670;&nbsp;</a></span>Vec2() <span class="overload">[1/4]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">constexpr nc::Vec2::Vec2 </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">constexpr</span><span class="mlabel">default</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Default Constructor </p>

</div>
</div>
<a id="aeb48b0300990a5b77919589488ddfe30"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aeb48b0300990a5b77919589488ddfe30">&#9670;&nbsp;</a></span>Vec2() <span class="overload">[2/4]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">constexpr nc::Vec2::Vec2 </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>inX</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>inY</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Constructor</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">inX</td><td>the x component </td></tr>
    <tr><td class="paramname">inY</td><td>the y component </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="abfb713c893dbd31d7c94b4741e82530b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abfb713c893dbd31d7c94b4741e82530b">&#9670;&nbsp;</a></span>Vec2() <span class="overload">[3/4]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">nc::Vec2::Vec2 </td>
          <td>(</td>
          <td class="paramtype">const std::initializer_list&lt; double &gt; &amp;&#160;</td>
          <td class="paramname"><em>inList</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Constructor</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">inList</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a93a9f0c675265005a60c77179625ddd2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a93a9f0c675265005a60c77179625ddd2">&#9670;&nbsp;</a></span>Vec2() <span class="overload">[4/4]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">nc::Vec2::Vec2 </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_nd_array.html">NdArray</a>&lt; double &gt; &amp;&#160;</td>
          <td class="paramname"><em>ndArray</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Constructor</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">ndArray</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a271ca2cae96a1df44486fbcc2c0f890f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a271ca2cae96a1df44486fbcc2c0f890f">&#9670;&nbsp;</a></span>angle()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::angle </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>otherVec</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the angle between the two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">otherVec</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the angle in radians </dd></dl>

</div>
</div>
<a id="abb0f6f8cacc680a464425d908e1e55cc"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abb0f6f8cacc680a464425d908e1e55cc">&#9670;&nbsp;</a></span>clampMagnitude()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::clampMagnitude </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>maxLength</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns a copy of the vector with its magnitude clamped to maxLength</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">maxLength</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="a63c2b2b7a16828af770d38176b6cb3aa"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a63c2b2b7a16828af770d38176b6cb3aa">&#9670;&nbsp;</a></span>distance()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::distance </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>otherVec</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the distance between the two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">otherVec</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the distance (equivalent to (a - b).<a class="el" href="classnc_1_1_vec2.html#ab6922f6c089b20e9d019301fddc6dc0a">norm()</a> </dd></dl>

</div>
</div>
<a id="a231781cc06b8f005a1dda5003498ec99"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a231781cc06b8f005a1dda5003498ec99">&#9670;&nbsp;</a></span>dot()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::dot </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>otherVec</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the dot product of the two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">otherVec</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the dot product </dd></dl>

</div>
</div>
<a id="a265ae124776dd84b657c4ff6d7677352"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a265ae124776dd84b657c4ff6d7677352">&#9670;&nbsp;</a></span>down()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::down </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the unit vector [0, -1]</p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="ade3f4342726264a1493f91ae80ab24ca"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ade3f4342726264a1493f91ae80ab24ca">&#9670;&nbsp;</a></span>left()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::left </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the unit vector [-1, 0]</p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="a91e6417e5b9903ed6bee3ad90c0c38f4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a91e6417e5b9903ed6bee3ad90c0c38f4">&#9670;&nbsp;</a></span>lerp()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::lerp </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>otherVec</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>t</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Linearly interpolates between two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">otherVec</td><td></td></tr>
    <tr><td class="paramname">t</td><td>the amount to interpolate by (clamped from [0, 1]); </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="ab6922f6c089b20e9d019301fddc6dc0a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab6922f6c089b20e9d019301fddc6dc0a">&#9670;&nbsp;</a></span>norm()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::norm </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the magnitude of the vector</p>
<dl class="section return"><dt>Returns</dt><dd>magnitude of the vector </dd></dl>

</div>
</div>
<a id="a8d8a3ec28ef8336ab02dcd964a3e836c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8d8a3ec28ef8336ab02dcd964a3e836c">&#9670;&nbsp;</a></span>normalize()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::normalize </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns a new normalized <a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a></p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="ac83768c682c162ec9dffe1bfb9637338"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac83768c682c162ec9dffe1bfb9637338">&#9670;&nbsp;</a></span>operator!=()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool nc::Vec2::operator!= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>rhs</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Not Equality operator</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">rhs</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>bool </dd></dl>

</div>
</div>
<a id="a72ac39ba88f909cb5552f6b379509f81"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a72ac39ba88f909cb5552f6b379509f81">&#9670;&nbsp;</a></span>operator*=()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator*= </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>scaler</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Scalar mulitplication</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">scaler</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="af441d4bbee40c07f9b86fbd056ff637e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af441d4bbee40c07f9b86fbd056ff637e">&#9670;&nbsp;</a></span>operator+=() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator+= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>rhs</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Adds the two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">rhs</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="a21b1c9c0aa0b7e8886f1b4a7c255bb9e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a21b1c9c0aa0b7e8886f1b4a7c255bb9e">&#9670;&nbsp;</a></span>operator+=() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator+= </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>scaler</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Adds the scaler to the vector</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">scaler</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="a13a2bbc2595248211e0bc97de51e13b5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a13a2bbc2595248211e0bc97de51e13b5">&#9670;&nbsp;</a></span>operator-=() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator-= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>rhs</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Subtracts the two vectors</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">rhs</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="abfb0b00888fa37d52a895d06f2b39133"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abfb0b00888fa37d52a895d06f2b39133">&#9670;&nbsp;</a></span>operator-=() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator-= </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>scaler</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Subtracts the scaler from the vector</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">scaler</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="a1a1c875b11ea5571cb2b71778a692472"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1a1c875b11ea5571cb2b71778a692472">&#9670;&nbsp;</a></span>operator/=()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a>&amp; nc::Vec2::operator/= </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>scaler</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Scalar division</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">scaler</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="af04a7f20ae8ac7a59ae44f7819668fa0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af04a7f20ae8ac7a59ae44f7819668fa0">&#9670;&nbsp;</a></span>operator==()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool nc::Vec2::operator== </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>rhs</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Equality operator</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">rhs</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>bool </dd></dl>

</div>
</div>
<a id="aa5cb2f954360d7be97c443da16694383"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa5cb2f954360d7be97c443da16694383">&#9670;&nbsp;</a></span>project()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::project </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classnc_1_1_vec2.html">Vec2</a> &amp;&#160;</td>
          <td class="paramname"><em>otherVec</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Projects the vector onto the input vector</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">otherVec</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="ab84fdd231058aa0343e2249e209855bf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab84fdd231058aa0343e2249e209855bf">&#9670;&nbsp;</a></span>right()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::right </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the unit vector [1, 0]</p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<a id="ad5f0e922730d66c57630ae5c7847e15a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad5f0e922730d66c57630ae5c7847e15a">&#9670;&nbsp;</a></span>toNdArray()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classnc_1_1_nd_array.html">NdArray</a>&lt;double&gt; nc::Vec2::toNdArray </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the <a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> as an <a class="el" href="classnc_1_1_nd_array.html" title="Holds 1D and 2D arrays, the main work horse of the NumCpp library.">NdArray</a></p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_nd_array.html" title="Holds 1D and 2D arrays, the main work horse of the NumCpp library.">NdArray</a> </dd></dl>

</div>
</div>
<a id="acd4277d3a9acded9199afef378e1907c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acd4277d3a9acded9199afef378e1907c">&#9670;&nbsp;</a></span>toString()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::string nc::Vec2::toString </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the <a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> as a string</p>
<dl class="section return"><dt>Returns</dt><dd>std::string </dd></dl>

</div>
</div>
<a id="a82fc65cffdae5c0ebd50fece54b56d4c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a82fc65cffdae5c0ebd50fece54b56d4c">&#9670;&nbsp;</a></span>up()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static constexpr <a class="el" href="classnc_1_1_vec2.html">Vec2</a> nc::Vec2::up </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the unit vector [0, 1]</p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classnc_1_1_vec2.html" title="Holds a 2D vector.">Vec2</a> </dd></dl>

</div>
</div>
<h2 class="groupheader">Field Documentation</h2>
<a id="a36a67b9395b397e1b8e9364a39a5c458"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a36a67b9395b397e1b8e9364a39a5c458">&#9670;&nbsp;</a></span>x</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::x { 0.0 }</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="ad7a5bc1612f92f7e49112cf58caeaace"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad7a5bc1612f92f7e49112cf58caeaace">&#9670;&nbsp;</a></span>y</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double nc::Vec2::y { 0.0 }</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_vec2_8hpp_source.html">Vec2.hpp</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespacenc.html">nc</a></li><li class="navelem"><a class="el" href="classnc_1_1_vec2.html">Vec2</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.17 </li>
  </ul>
</div>
</body>
</html>
